import request from "@/utils/request";
import {createFileMd5} from "@/utils/tools";
const upload = async (data) => {
    return request({
        url: "/file/upload",
        method: "post",
        headers: {
            'Content-Type': "multipart/form-data",
        },
        data
    })
}

const deleteFile = (fileId) => {
    return request({
        url: "/file/delete/"+fileId,
        method: "delete"
    })
}

export {
    upload,
    deleteFile
}
